let app = getApp();
let that = null;
Page({
  data:{
    winW:0,
    winH:0,
    selectType:0,
    data:[{tTitle:'新品优惠',
          tImg:'../../img/1.jpg',
          tNum:0,
          products:[{pTitle:'牛油果双人套餐',pImg:'../../img/2.jpg',pNum:0,pPrice:21.0},
                    {pTitle:'奥尔良鸡腿堡',pImg:'../../img/3.jpg',pNum:0,pPrice:16.5},
                    {pTitle:'烤鸡翅',pImg:'../../img/3.jpg',pNum:0,pPrice:18.8},
                    {pTitle:'麦香鸡腿堡',pImg:'../../img/5.jpg',pNum:0,pPrice:16.0},
                    {pTitle:'麦香鸡腿堡',pImg:'../../img/5.jpg',pNum:0,pPrice:16.2}]
          },
          {tTitle:'超值全家桶',
          tImg:'../../img/2.jpg',
          tNum:0,
          products:[{pTitle:'牛油果双人套餐',pImg:'../../img/2.jpg',pNum:0,pPrice:21},
                    {pTitle:'奥尔良鸡腿堡',pImg:'../../img/3.jpg',pNum:0,pPrice:16},
                    {pTitle:'烤鸡翅',pImg:'../../img/3.jpg',pNum:0,pPrice:18},
                    {pTitle:'麦香鸡腿堡',pImg:'../../img/5.jpg',pNum:0,pPrice:16}]
          },
          {tTitle:'新品优惠',
          tImg:'../../img/3.jpg',
          tNum:0,
          products:[{pTitle:'牛油果双人套餐',pImg:'../../img/2.jpg',pNum:0,pPrice:21},
                    {pTitle:'奥尔良鸡腿堡',pImg:'../../img/3.jpg',pNum:0,pPrice:16},
                    {pTitle:'烤鸡翅',pImg:'../../img/3.jpg',pNum:0,pPrice:18},
                    {pTitle:'麦香鸡腿堡',pImg:'../../img/5.jpg',pNum:0,pPrice:16}]
          },
          {tTitle:'新品优惠',
          tImg:'../../img/4.jpg',
          tNum:0,
          products:[{pTitle:'牛油果双人套餐',pImg:'../../img/2.jpg',pNum:0,pPrice:21},
                    {pTitle:'奥尔良鸡腿堡',pImg:'../../img/3.jpg',pNum:0,pPrice:16},
                    {pTitle:'烤鸡翅',pImg:'../../img/3.jpg',pNum:0,pPrice:18},
                    {pTitle:'麦香鸡腿堡',pImg:'../../img/5.jpg',pNum:0,pPrice:16}]
          },
          {tTitle:'新品优惠',
          tImg:'../../img/5.jpg',
          tNum:0,
          products:[{pTitle:'牛油果双人套餐',pImg:'../../img/2.jpg',pNum:0,pPrice:21},
                    {pTitle:'奥尔良鸡腿堡',pImg:'../../img/3.jpg',pNum:0,pPrice:16},
                    {pTitle:'烤鸡翅',pImg:'../../img/3.jpg',pNum:0,pPrice:18},
                    {pTitle:'麦香鸡腿堡',pImg:'../../img/5.jpg',pNum:0,pPrice:16}]
          },
          {tTitle:'新品优惠',
          tImg:'../../img/1.jpg',
          tNum:0,
          products:[{pTitle:'牛油果双人套餐',pImg:'../../img/2.jpg',pNum:0,pPrice:21},
                    {pTitle:'奥尔良鸡腿堡',pImg:'../../img/3.jpg',pNum:0,pPrice:16},
                    {pTitle:'烤鸡翅',pImg:'../../img/3.jpg',pNum:0,pPrice:18},
                    {pTitle:'麦香鸡腿堡',pImg:'../../img/5.jpg',pNum:0,pPrice:16}]
          },
          {tTitle:'新品优惠',
          tImg:'../../img/1.jpg',
          tNum:0,
          products:[{pTitle:'牛油果双人套餐',pImg:'../../img/2.jpg',pNum:0,pPrice:21},
                    {pTitle:'奥尔良鸡腿堡',pImg:'../../img/3.jpg',pNum:0,pPrice:16},
                    {pTitle:'烤鸡翅',pImg:'../../img/3.jpg',pNum:0,pPrice:18},
                    {pTitle:'麦香鸡腿堡',pImg:'../../img/5.jpg',pNum:0,pPrice:16}]
          },
          {tTitle:'新品优惠',
          tImg:'../../img/1.jpg',
          tNum:0,
          products:[{pTitle:'牛油果双人套餐',pImg:'../../img/2.jpg',pNum:0,pPrice:21},
                    {pTitle:'奥尔良鸡腿堡',pImg:'../../img/3.jpg',pNum:0,pPrice:16},
                    {pTitle:'烤鸡翅',pImg:'../../img/3.jpg',pNum:0,pPrice:18},
                    {pTitle:'麦香鸡腿堡',pImg:'../../img/5.jpg',pNum:0,pPrice:16}]
          }
          ]
  },
  onLoad:function(options){
    // 生命周期函数--监听页面加载
    that = this;
    that.setData({
      winW:app.globalData.winW,
      winH:app.globalData.winH
    });
    console.log(that.data.winW);
    console.log(that.data.winH);
   
  },
  onReady:function(){
    // 生命周期函数--监听页面初次渲染完成
  
  },
  onShow:function(){
    // 生命周期函数--监听页面显示
    
  },
  onHide:function(){
    // 生命周期函数--监听页面隐藏
   
  },
  onUnload:function(){
    // 生命周期函数--监听页面卸载
   
  },
  onPullDownRefresh: function() {
    // 页面相关事件处理函数--监听用户下拉动作
   
  },
  onReachBottom: function() {
    // 页面上拉触底事件的处理函数
   
  },
  onShareAppMessage: function() {
    // 用户点击右上角分享
    return {
      title: 'title', // 分享标题
      desc: 'desc', // 分享描述
      path: 'path' // 分享路径
    }
  }
})
